<template>
  <div id="app">
    <Skeleton v-if="isLogin">
      <div slot="content">
        <keep-alive :exclude="reg">
          <router-view></router-view>
        </keep-alive>
      </div>
    </Skeleton>
    <Login v-else></Login>
  </div>
</template>

<script>
import Skeleton from "@/views/Skeleton";
import Login from "@/views/Login";
export default {
  data() {
    return {};
  },
  computed: {
    isLogin() {
      return this.$store.state.isLogin;
    },
    reg() {
      return /ForgeHeroUpdate|TechAdd|EquUpdate|AniUpdate|GeographyAddorUpdate|AchUpdate|ArticleAdd/;
    }
  },
  components: {
    Skeleton,
    Login
  }
};
</script>
<style lang="scss">
* {
  margin: 0;
  padding: 0;
}
#app {
  font-family: "Avenir", Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
</style>
